package com.ptswitch.material.dao.impl;

import java.util.List;

import org.hxzon.project.IbatisDao;
import org.springframework.stereotype.Repository;

import com.ptswitch.material.model.common.EMailAddress;
@Repository
public class EMailAddressDao extends IbatisDao {
    public void delete(String id) {
        super.delete("", id);
    }

    public List<EMailAddress> findAll() {
        return super.list(EMailAddress.class, "");
    }

    public void save(EMailAddress model) {
        if (model.getId() == null) {
            super.insert("", model);
        } else {
            super.update("", model);
        }
    }
}
